package com.hqj.controller;

import com.hqj.service.HomesServiceI;
import com.hqj.util.HightChartUtil;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import javax.annotation.Resource;

@Controller
@RequestMapping("/rc")
public class ReportController {

    @Resource(name="homesServiceI")
    private HomesServiceI hsi;


    @RequestMapping("/base-pie")
    public String basePie(){
        return "pages/report/base-pie";
    }

    @RequestMapping("/getBasePieJson")
    @ResponseBody
    public String getBasePieJson(){
        return hsi.createBasePie();
    }

    @RequestMapping("/base-line-column-bar")
    public String baseLineColumnBar(){
        return "pages/report/base-line-column-bar";
    }

    @RequestMapping("/getBaseLineColumnBar")
    @ResponseBody
    public String getBaseLineColumnBar(){
        return hsi.createLineBarColumn();
    }

}
